package agents.task;

import agents.resource.ResourceAgent;

//een stap in een trip; is immutable
public class TripStep {
	public TripStep(ResourceAgent ti, long enterTime) {
		this.enterTime = enterTime;
		this.resourceAgent = ti;
	}
	
	public ResourceAgent getResourceAgent() {
		return resourceAgent;
	}

	public long getEnterTime() {
		return enterTime;
	}
	
	@Override
	public String toString() {
		return (resourceAgent == null ? "next" : resourceAgent.getTrafficInfrastructure().getId()) + " at time " + enterTime;
	}

	private final ResourceAgent resourceAgent;
	private final long enterTime;
}
